package extends_dir;

public class exec {
    public static void main(String[] args) {
        Animal a = new Animal("animal",1);
        a.eat();
        Penguin p = new Penguin("penguin", 123);
        Penguin_extend p_e = new Penguin_extend("penguin_extend", 123);
        dog_extends d_e = new dog_extends("dog",123);
        p.eat();
        // p.show_id(); //此处没有继承，故无法使用
        p_e.show_id();
        p_e.eat();
        p_e.sleep();
        p_e.introduction();
        Dog d = new Dog("dog",22);
        d.eattest();
        d.eat();
        System.out.println("------------------");
        d_e.eat();
        d_e.show_id();
    }
}
